#!/usr/bin/python

from tkinter import *

def callback():
    var.set('Hi')


app = Tk()

frame1 = Frame(app)
frame2 = Frame(app)

var = StringVar()
var.set("Hello")

label = Label(frame1, textvariable=var, justify=LEFT)
label.pack(side=LEFT)

photo = PhotoImage(file='example.gif')

imglabel = Label(frame1, image=photo)
imglabel.pack(side=LEFT)

button = Button(frame2, text='ok', command = callback)
button.pack(side=RIGHT)

frame1.pack(padx=10, pady=10)
frame2.pack(padx=10, pady=10)

app.mainloop()
